package cn.zwxky.android.staff.Jurisdiction.Marketplace;

import android.app.Activity;
import android.app.Fragment;
import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import com.zgscwjm.lsfbbasetemplate.Event.LsfbEvent;
import com.zgscwjm.lsfbbasetemplate.annotation.OnClick;
import com.zgscwjm.lsfbbasetemplate.annotation.ViewInjectUtils;

import cn.zwxky.android.staff.R;

/**
 * Created by Administrator on 2017/3/31 0031.
 */

public class ReleaseTask extends Fragment {
    /**
     * view对象
     */
    private View view;

    /**
     * activity对象
     */
    private Activity mactivity;
    @Nullable
    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
        view = inflater.inflate(R.layout.fragment_release_task, null);
        ViewInjectUtils.inject(this, view);



        return view;
    }

    /**
     * 用于存储activity对象
     *
     * @param activity
     */
    @Override
    public void onAttach(Activity activity) {
        super.onAttach(activity);
        mactivity = activity;
    }

    @OnClick({R.id.item_release_task})
    public void onClick(View view){
        switch (view.getId()){
            case R.id.item_release_task:
                 startActivity(new Intent(mactivity, ReleaseTaskDetailsActivity.class));
                break;
        }
    }

    public void getData(){

    }


    @Override
    public void onResume() {
        super.onResume();
        LsfbEvent.getInstantiation().register2(this);
    }

    @Override
    public void onStop() {
        super.onStop();
        LsfbEvent.getInstantiation().unregister2(this);
    }

}
